import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

public class StudentTest {
    public static void main(String[] args) {
        List<Student> list=new ArrayList<Student>();
        Student stu1=new Student(1001,"刘备","男",25,99);
        Student stu2=new Student(1002,"关羽","男",20,89);
        Student stu3=new Student(1003,"张飞","男",19,88);
        Student stu4=new Student(1004,"孙尚香","女",18,79);
        Student stu5=new Student(1005,"大乔","女",21,56);
        Collections.addAll(list,stu1,stu2,stu3,stu4,stu5);
        System.out.println("{"+stu1+"}");
        System.out.println("{"+stu2+"}");
        System.out.println("{"+stu3+"}");
        System.out.println("{"+stu4+"}");
        System.out.println("{"+stu5+"}");

        System.out.println("五个学生的平均分是"+Tool.getAvg(list));
        System.out.println("五个学生中的最高分的学生信息是："+Tool.getMax(list));
        System.out.println("五个学生中的最低分的学生信息是："+Tool.getMin(list));

    }

}
